(1) Field of the Invention
The present invention relates to methods for operating data loggers. In particular, the invention provides software techniques useful for controlling the critical functions of low-power-battery-operated data loggers.
(2) Description of the Prior Art
Generally speaking, data loggers are devices that record measurements obtained from electronic sensors that sense physical properties such as temperature, pressure, electrical current and voltage among others. A conventional data logger is made up of a digital processor operationally connected to a non-volatile memory bank for storing measurements obtained from electronic sensors in communication with the data logger. Other major components include at least one digital communication port for communicating with an external user interface device such as a personal computer (PC) or personal digital assistant (PDA) and a real-time clock for keeping track of time as well as calendar dates. Additional components can include sensor interfaces such as analog-to-digital converters and event counters used to convert analog signals and discrete events into digital form for storage into the non-volatile memory bank.
The external user interface device allows a user to transfer recorded data from a data logger to a data processor so that the recorded data can be processed and presented in a useful manner. Furthermore, most, if not all data loggers have settings and parameters that must be initialized by the user. For example, conventional data loggers have real-time clock and calendar variables that must be set by the user. In order to set these variables, a user typically transfers values for the variables to a data logger through a PDA running software having a graphical user interface that includes a clock/calendar settings form. After the user inputs the desired clock/calendar settings into the PDA by way of the settings form, the user invokes a communication session between the PDA and data logger to transfer the desired clock/calendar settings to the data logger. The communication can take place over a wireless or hardwired communications channel shared by the PDA and data logger. Other user settings can include data formats and operational mode settings.
Data loggers are typically operated in one of two data collecting modes. The most prevalent mode is time-based mode. In this mode, a data logger is scheduled to obtain data readings from a sensor or number of sensors at a given time interval. For example, a user could schedule a temperature data logger to record temperature readings obtained from an electronic thermometer at a rate of one reading every ten minutes.
Once the desired recording interval and other user settings are transferred to the data logger, the data logger typically goes into a sleep mode to conserve the energy of a battery powering the data logger. Sleep modes for data loggers, generally place processors and communication ports into a power conserving state. For example, a conventional sleep mode usually disables the clock oscillator supplying the instruction cycle timing to a data logger's digital processor, thereby halting the processor. Halting a data logger's digital processor is a major technique for conserving energy.
Traditional time-based data loggers have digital processors that have an interrupt signal line connected to the logical output of an alarm function controlled by a real-time clock. If the data logger in the previous example is equipped with a real-time clock with an alarm function, the processor of the data logger will receive an alarm signal generated by the real-time clock's alarm function every ten minutes. The alarm signal will interrupt and wake the data logger from the sleep mode. Once awake, the data logger will obtain a temperature reading, record the reading and go back into the sleep mode until another alarm signal is generated ten minutes later. Data logging intervals typically range from fractions of a second for rapidly changing sensor data to once per day for slow changing sensor data.
Another operating mode for data loggers is event driven. In an event driven operating mode, a data logger only records data when triggered by an external event. For example, a seismic activity data recorder will only begin recording data after its associated seismic sensor detects a seismic event of a certain predetermined magnitude.
Numerous other operating modes and features are incorporated into modern data loggers. For example, an increasing number of commercially available data loggers have in-circuit firmware programming capability. This capability allows a user to erase a data logger's current firmware and upload new firmware. While the ability to revise a data logger's firmware is a significant advance, an unforeseen problem has surfaced relative to this new capability.
The problem occurs whenever a user programs new firmware into the data logger, but forgets to reinitialize variables such as data memory pointers, etc. Forgetting to initialize data memory pointers after a firmware upload can result in a permanent loss of important data. Removing the data memory pointer initialization burden from the user would be of substantial benefit to the user.
Another previously unsolved problem pertains to attaining baud rates greater than 19.2 kbps between a sleep mode operated data logger and an external user interface device such as a PDA. Receiving a data stream in sleep mode generally involves waking up, receiving a character and then going back to sleep until another character arrives. Up to now, a data logger operating from a sleep mode could not receive a data stream at a baud rate higher than 19.2 kbps because of delays resulting from the data logger's wake-up procedures. In order to receive a data stream at a higher baud rate than 19.2 kbps, prior art communication methods required the processor of a data logger to operate in a mode other than a sleep mode. Unfortunately, operating outside of a sleep mode during a communication session results in excessive energy consumption of a data logger's primary power source. In fact, the battery consumption rate can be tens of times higher than when communicating in sleep mode. What is needed is a computerized method that retains the benefits of sleep mode operation while at the same time maintains the ability to receive data streams at baud rates higher than 19.2 kbps.
Still yet another problem, involves estimating remaining battery capacity of the primary power source. Prior art methods for estimating remaining battery capacity generally rely on a data logger being equipped to measure it's own battery's characteristics. The characteristics typically measured, are battery voltage, battery current and battery temperature. While some of these prior art methods provide reasonably accurate results, they do so at significant disadvantages relative to low power data logger operation. First of all, in order to make the appropriate measurements, extra sensors are needed to make the measurements. Secondly, these extra sensors require power to operate, creating additional loads for the data logger's battery. What is needed is a method for estimating remaining battery life that does not require a data logger to measure its own battery's characteristics.
Another problem lacking an adequate solution up to this point, is due to primary power source disruptions that result in the loss of crucial variable data such as data memory pointers, alarm intervals and the like. The most worrisome power disruptions happen during transportation of data loggers to field sites. Power disruptions can occur when the battery powering a data logger is shaken in its holder, causing momentary loss of power as the battery disconnects and reconnects to the holder's terminals. Another lengthier, yet predictable power disruption occurs whenever the battery is removed from its holder making room for its replacement. If the battery is not quickly reinstalled, residual energy stored in filter capacitors will drain down to a point to which volatile memory locations are corrupted. What is needed is a computerized method that will protect the contents of crucial memory locations during primary power source disruptions.